<% if current_member then %> 

  <%= form_for(@comment) do |f| %>
      
      <% if @post != nil %>
        <%= hidden_field_tag 'post_id', @post.id %>
      <% end %>
      
      <% if @tutorial != nil %>
        <%= hidden_field_tag 'tutorial_id', @tutorial.id %>
      <% end %>
      
      <div class="field">
        <%= f.text_area :content, :class => 'wide' %>
      </div>
        <%= f.submit 'Spremi' %>
  <% end %>
<% else %>   
    <div class="comment_login">     
    <%= link_to 'Prijavi se', new_member_session_path %> kako bi mogao komentirati.
    </div>
<% end %>